package cn.boysoft.module.security.model.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import cn.boysoft.core.annotation.JEEEntityDeclare;
import cn.boysoft.core.model.entity.BaseEntity;

@Table(name = "jee_org")
@Entity
@JEEEntityDeclare(name = "组织机构信息")
public class OrgEntity extends BaseEntity {
	@Column(length = 36)
	private String name;
	@Column(length = 36)
	private String chargeMan;
	@Column(length = 36)
	private String phone;
	@Column(length = 255)
	private String address;
	@Column(length = 255)
	private String functions;
	@ManyToOne
	@JoinColumn(name = "parentId")
	private OrgEntity parentOrg;

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getChargeMan() {
		return chargeMan;
	}

	public void setChargeMan(String chargeMan) {
		this.chargeMan = chargeMan;
	}

	public String getPhone() {
		return phone;
	}

	public void setPhone(String phone) {
		this.phone = phone;
	}

	public String getAddress() {
		return address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	public String getFunctions() {
		return functions;
	}

	public void setFunctions(String functions) {
		this.functions = functions;
	}

	public OrgEntity getParentOrg() {
		return parentOrg;
	}

	public void setParentOrg(OrgEntity parentOrg) {
		this.parentOrg = parentOrg;
	}
}
